using System;
using Phoenix.ActionResults;
using Phoenix.Frames;

namespace Phoenix.Tests.Framework
{
    public class DelegateActionResult : ActionResult
    {
        readonly Action action;

        public DelegateActionResult(Action action) : base(null)
        {
            this.action = action;
        }

        public override void Execute(IContentFrame targetFrame)
        {
            action();
        }
    }
}